<?php

namespace app\index\validate;

use think\Validate;

class Editor extends Validate
{
  protected $rule = [
    'title'=>'max:255',
    'content'=>'max:5000',
    'coverImage'=>'max:255'
  ];
  protected $message = [
    'title.max'=>'标题过长已经超过最大限制250个字',
    'content.max'=>'内容过长已经超过最大限制5000个字',
    'coverImage.max'=>'缩略图路径过长',
  ];
  protected $scene = [
    'create' =>['title', 'content', 'coverImage'],
  ];
}
